import Vue from 'vue'
import App from './App.vue'
import './lib/css/mui.css'
import './lib/css/icons-extra.css'
import VueRouter from 'vue-router';
import router from './router.js';//导入路由
import MintUI from 'mint-ui';//导入mintui
import 'mint-ui/lib/style.css';//导入nint-ui.css
Vue.use(VueRouter) //引用vuerouter
 Vue.use(MintUI);//引用mintui
// import { Swipe, SwipeItem } from 'mint-ui';
// Vue.use({ Swipe, SwipeItem })
// // Vue.component(Swipe.name, Swipe);
// // Vue.component(SwipeItem.name, SwipeItem);

import axios from 'axios';

axios.defaults.baseURL = 'http://www.barteam.cn:8086';//axios默认基础路由
Vue.prototype.$ajax = axios;

import Moment from 'moment';//引入时间格式化包moment.js
//格式化日期过滤器
Vue.filter('dateFormat',function(dateStr, pattern = 'YYYY--MM--DD HH:MM'){
  return  Moment(dateStr).format(pattern);
})
import VuePreview from 'vue-preview'
Vue.use(VuePreview);
//导入vuex仓储模块
import store from './store.js'
new Vue({
  el:'#app',
  render: h => h(App), //render渲染函数
  router, //挂载router
  store, //挂载store
})
